package org.example.controller;


import org.example.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Controller;

import javax.annotation.Resource;

@Controller
@Scope("prototype")
public class UserController {

    @Autowired
    private String zhangsan;
    public String getZhangsan() {
        return zhangsan;
    }
    public void setZhangsan(String zhangsan) {
        this.zhangsan = zhangsan;
    }

    private String zhangsan2;
    public String getZhangsan2() {
        return zhangsan2;
    }
    public void setZhangsan2(String zhangsan2) {
        this.zhangsan2 = zhangsan2;
    }

    @Autowired
    private UserService userService;
    public UserService getUserService() {
        return userService;
    }
    public void setUserService(UserService userService) {
        this.userService = userService;
    }


    @Autowired
    private UserService us1;
    public UserService getUs1() {
        return us1;
    }
    public void setUs1(UserService us1) {
        this.us1 = us1;
    }

    @Autowired
    @Resource(name="us2")
//    @Qualifier("us2")
    private UserService ushahah;
    public UserService getUshahah() {
        return ushahah;
    }
    public void setUshahah(UserService ushahah) {
        this.ushahah = ushahah;
    }





}
